using System;
using System.Collections.Generic;
using System.Text;
using System.Xml;

namespace Axe.Xml
{
    /*
    public class XmlMappingNode
    {
        Type m_ValueType;
        string m_ElementName;
        object m_Value;

        public string ElementName
        {
            get { return m_ElementName; }
            set { m_ElementName = value; }
        }

        public object Value
        {
            get { return m_Value; }
            set { m_Value = value; }
        }

        public XmlMappingNode()
        {

        }

        List<XmlMappingNode> m_Nodes = new List<XmlMappingNode>();

        public List<XmlMappingNode> Nodes
        {
            get { return m_Nodes; }
            set { m_Nodes = value; }
        }

        internal void Read(XmlReader reader)
        {
            while (reader.Read())
            {
                switch (reader.NodeType)
                {
                    case XmlNodeType.Element:

                };
            }

        }

        internal void Write(XmlWriter writer)
        {
            writer.WriteStartElement(m_ElementName);
            writer.WriteValue(Value);

            if (m_Nodes != null)
            {
                m_Nodes.ForEach(delegate(XmlMappingNode node) { node.Write(writer); });
            }

            writer.WriteEndElement();
        }
    }


    public class XmlMapping
    {
        Type m_ObjectType;
        string m_ObjectName;

        public Type ObjectType
        {
            get { return m_ObjectType; }
            set { m_ObjectType = value; }
        }
        

        public string ObjectName
        {
            get { return m_ObjectName; }
            set { m_ObjectName = value; }
        }

        public XmlMapping()
        {

        }
    }

    public class XmlMapper
    {
        public void WriteXml(XmlWriter writer, XmlMapping mapping,object)
        {
            writer.WriteStartElement(mapping.Name);
            writer.WriteAttributeString("Type", mapping.ObjectType.Name);
            writer.WriteValue(mapping.



            //writer.WriteEndElement();
        }
    }
    */
}
